import request from '@/utils/request'

// 查询车位授权列表
export function listAuthorization(query) {
  return request({
    url: '/system/authorization/list',
    method: 'get',
    params: query
  })
}

// 查询车位授权详细
export function getAuthorization(authid) {
  return request({
    url: '/system/authorization/' + authid,
    method: 'get'
  })
}

// 新增车位授权
export function addAuthorization(data) {
  return request({
    url: '/system/authorization',
    method: 'post',
    data: data
  })
}

// 修改车位授权
export function updateAuthorization(data) {
  return request({
    url: '/system/authorization',
    method: 'put',
    data: data
  })
}

// 删除车位授权
export function delAuthorization(authid) {
  return request({
    url: '/system/authorization/' + authid,
    method: 'delete'
  })
}
